package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

/**
 * 促销商品表
 */

@TableName("t_discount")
public class DiscountBean {
    /**
     * id
     */
    @TableId(value = "pk_discountId",type = IdType.AUTO)
    private Integer id;
    /**
     * 商品编号
     */
    @TableField("shopId")
    private String shopId;
    /**
     * 商品名
     */
    @TableField("shopName")
    private String shopName;
    /**
     * 商品数量
     */
    @TableField("num")
    private int num;
    /**
     * 商品规格
     */
    @TableField("size")
    private String size;
    /**
     * 商品规格
     */
    @TableField("color")
    private String color;
    /**
     * 商品原价
     */
    @TableField("origina")
    private double origina;
    /**
     * 促销折扣
     */
    @TableField("discount")
    private double discount=1;//默认折扣为1，表示未打折
    /**
     * 是否促销
     */
    @TableField("Promotion")
    private String Promotion="未促销";//0-未促销，1-促销
    /**
     * 类型
     */
    @TableField("type")
    private String type;

    public DiscountBean() {
    }

    public DiscountBean(Integer id, String shopId, String shopName, String size, String color, double origina, double discount, String type) {
        this.id = id;
        this.shopId = shopId;
        this.shopName = shopName;
        this.size = size;
        this.color = color;
        this.origina = origina;
        this.discount = discount;
        this.type = type;
    }

    public DiscountBean(Integer id, String shopId, String shopName, String size, String color, double origina, double discount, String promotion, String type) {
        this.id = id;
        this.shopId = shopId;
        this.shopName = shopName;
        this.size = size;
        this.color = color;
        this.origina = origina;
        this.discount = discount;
        Promotion = promotion;
        this.type = type;
    }

    public DiscountBean(Integer id, String shopId, String shopName, int num, String size, String color, double origina, double discount, String promotion, String type) {
        this.id = id;
        this.shopId = shopId;
        this.shopName = shopName;
        this.num = num;
        this.size = size;
        this.color = color;
        this.origina = origina;
        this.discount = discount;
        Promotion = promotion;
        this.type = type;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getShopId() {
        return shopId;
    }

    public void setShopId(String shopId) {
        this.shopId = shopId;
    }

    public String getShopName() {
        return shopName;
    }

    public void setShopName(String shopName) {
        this.shopName = shopName;
    }

    public String getSize() {
        return size;
    }

    public void setSize(String size) {
        this.size = size;
    }

    public String getColor() {
        return color;
    }

    public void setColor(String color) {
        this.color = color;
    }

    public double getOrigina() {
        return origina;
    }

    public void setOrigina(double origina) {
        this.origina = origina;
    }

    public double getDiscount() {
        return discount;
    }

    public void setDiscount(double discount) {
        this.discount = discount;
    }

    public String getPromotion() {
        return Promotion;
    }

    public void setPromotion(String promotion) {
        Promotion = promotion;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public int getNum() {
        return num;
    }

    public void setNum(int num) {
        this.num = num;
    }

    @Override
    public String toString() {
        return "DiscountBean{" +
                "id=" + id +
                ", shopId='" + shopId + '\'' +
                ", shopName='" + shopName + '\'' +
                ", num=" + num +
                ", size='" + size + '\'' +
                ", color='" + color + '\'' +
                ", origina=" + origina +
                ", discount=" + discount +
                ", Promotion='" + Promotion + '\'' +
                ", type='" + type + '\'' +
                '}';
    }
}
